package com.yanqu.road.server.cmd.activity.dafuweng.cross;

import com.yanqu.road.pb.monopoly.CrossMonopolyProto;
import com.yanqu.road.server.cmd.base.AbstractCommand;
import com.yanqu.road.server.command.Cmd;
import com.yanqu.road.server.gameplayer.GamePlayer;
import com.yanqu.road.server.manger.activity.dafuweng.DaFuWengMgr;
import com.yanqu.road.message.YanQuMessage;
import com.yanqu.road.server.protocol.GameProtocol;

@Cmd(code = GameProtocol.S_DA_FU_WENG_CROSS_UNION_REBATE,desc = "")
public class DfwUnionRebateResultCmd extends AbstractCommand {
    @Override
    public boolean parseData(YanQuMessage packet) throws Exception {
        return true;
    }

    @Override
    public void execute(GamePlayer player, YanQuMessage packet) throws Exception {
        CrossMonopolyProto.CrossDfwUnionRebateRespMsg rebateRespMsg = CrossMonopolyProto.CrossDfwUnionRebateRespMsg.parseFrom(packet.getBytes());
        int activityId = rebateRespMsg.getActivityId();
        String unionId = rebateRespMsg.getUnionId();
        int times = rebateRespMsg.getTimes();
        DaFuWengMgr.getUnionRebate(player,times);
    }

    @Override
    public void sendData(GamePlayer player) {

    }
}
